package com.sc.nft.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.sc.nft.entity.SalvageEventsDetails;
import com.sc.nft.entity.dto.SalvageEventsRewardsDTO;
import com.sc.nft.entity.vo.UserHoldTicketDetailsVO;
import com.sc.nft.entity.vo.salvageEvents.AdminsAlvageEventsCollectionDetailsVO;
import com.sc.nft.entity.vo.salvageEvents.SalvageEventsScreenVO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 分解活动藏品奖励表(sc_salvage_events_details)数据Mapper
 *
 * @author Sun
 * @description 由 Mybatisplus Code Generator 创建
 * @since 2023-08-10 13:40:55
 */
@Mapper
public interface SalvageEventsDetailsMapper extends BaseMapper<SalvageEventsDetails> {

    /**
     * 后台获取分解活动详情
     *
     * @param salvageEventsId
     * @return
     */
    List<AdminsAlvageEventsCollectionDetailsVO> getAdminDetailsBysalvageEventsId(@Param("salvageEventsId") Long salvageEventsId);

    /**
     * 获取分解活动藏品id
     *
     * @param salvageEventsId
     * @return
     */
    List<Long> getCollectionIdBySalvageEventsId(@Param("salvageEventsId") Long salvageEventsId);

    List<SalvageEventsRewardsDTO> getFixedPreSalvageReward(@Param("salvageEventsId") Long salvageEventsId, @Param("userCollectionIds") List<Long> userCollectionIds);

    List<Long> getProportionPreSalvageReward(@Param("salvageEventsId") Long salvageEventsId, @Param("userCollectionIds") List<Long> userCollectionIds);

    /**
     * 获取分解活动包含的藏品
     *
     * @param salvageEventsId
     * @return
     */
    List<SalvageEventsScreenVO> getSalvageEventsScreen(@Param("salvageEventsId") Long salvageEventsId);

    /**
     * 获取分解活动包含的藏品
     *
     * @param salvageEventsId
     * @param collectionIds
     * @return
     */
    List<Long> getCollectionIdBySalvageEventsIdAndCollectionIds(@Param("salvageEventsId") Long salvageEventsId, @Param("collectionIds") List<Long> collectionIds);

    /**
     * 获取分解活动的条件,以及基础信息
     *
     * @param salvageEventsId
     * @return
     */
    List<UserHoldTicketDetailsVO> getCInfoBySalvageEventsId(@Param("salvageEventsId") Long salvageEventsId);
}
